package com.ruyuan.eshop.inventory.api;

import com.ruyuan.eshop.common.core.JsonResult;
import com.ruyuan.eshop.inventory.domain.request.DeductProductStockRequest;
import com.ruyuan.eshop.inventory.domain.request.ReleaseProductStockRequest;

/**
 * @Author zhonghuashishan
 * @Remark 有问题直接联系客服VX: ruyuan-1111 ，源码-笔记-技术交流群
 * @Version 1.0
 **/

public interface InventoryApi {

    /**
     * 扣减商品库存
     *
     * @param deductProductStockRequest
     * @return
     */
    JsonResult<Boolean> deductProductStock(DeductProductStockRequest deductProductStockRequest);

    /**
     * 取消订单 释放商品库存
     */
    JsonResult<Boolean> releaseProductStock(ReleaseProductStockRequest releaseProductStockRequest);
}